package com.neusoft.controller.registration;

import com.neusoft.service.DrugInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.CrossOrigin;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.List;
import java.util.Map;

@RestController
@RequestMapping("/druginfos")
@CrossOrigin
public class DrugInfoController {

    @Autowired
    private DrugInfoService drugInfoService;

    //根据姓名和病历号查询患者费用记录
    @GetMapping("/searchInformation")
    public List<Map<String, Object>> searchInformation(String caseNumber, String realName){
        List<Map<String,Object>> list=drugInfoService.searchInformation(caseNumber,realName);
        return list;
    }
}
